package com.xfatm.killer.ui;

import android.os.Bundle;
import android.os.PersistableBundle;
import android.support.annotation.Nullable;
import android.support.v7.app.AppCompatActivity;

import com.xfatm.killer.util.Activitys;

/**
 * Created by wenjie on 2018/3/24.
 */

public class BaseActivity extends AppCompatActivity {

    @Override
    protected void onStart() {
        super.onStart();
        Activitys.setTopAndAdd(this);
    }

    @Override
    public void onCreate(@Nullable Bundle savedInstanceState, @Nullable PersistableBundle persistentState) {
        super.onCreate(savedInstanceState, persistentState);
        Activitys.setTopAndAdd(this);
    }

    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        Activitys.setTopAndAdd(this);
    }

    @Override
    protected void onDestroy() {
        super.onDestroy();
        Activitys.destory(this);
    }
}
